package com.hongyi.system.domain.dto;


import com.hongyi.common.framework.validate.AddGroup;
import com.hongyi.common.framework.validate.EditGroup;
import com.hongyi.common.mybatis.domain.BaseEntity;
import com.hongyi.system.domain.SysDept;
import io.github.linpeilie.annotations.AutoMapper;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;


/**
 * 系统部门信息表
 */
@ApiModel(description="系统部门信息表")
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = SysDept.class)
public class SysDeptDto extends BaseEntity {

    /**
     * 部门id
     */
    @ApiModelProperty(value="部门id")
    private Long deptId;

    /**
     * 父部门id
     */
    @ApiModelProperty(value="父部门id")
    private Long parentId;

    /**
     * 部门名称
     */
    @NotBlank(message = "部门名称不能为空", groups = {AddGroup.class, EditGroup.class})
    @ApiModelProperty(value="部门名称")
    private String deptName;

    /**
     * 显示顺序
     */
    @NotNull(message = "显示顺序不能为空", groups = {AddGroup.class, EditGroup.class})
    @ApiModelProperty(value="显示顺序")
    private Integer orderNum;

    /**
     * 负责人
     */
    @ApiModelProperty(value="负责人")
    private String leader;

    /**
     * 联系电话
     */
    @ApiModelProperty(value="联系电话")
    private String phone;

    /**
     * 邮箱
     */
    @ApiModelProperty(value="邮箱")
    private String email;

    /**
     * 部门状态（0正常 1停用）
     */
    @NotBlank(message = "部门状态不能为空", groups = {EditGroup.class})
    @ApiModelProperty(value="部门状态（0正常 1停用）")
    private String status;




}